export default {
    template:`
    <div class="film-item">
        <img class="img" :src="film.filmImg" alt="" srcset="">
        <div class="name">{{ film.filmName }}</div>
        <div class="stars" v-if="film.source==null">
            <span class="source">暂无评分</span>
        </div>
        <div class="stars" v-else>
            <i class="iconfont icon-collection-b"
                v-for="c in 5"
                :class=" { active: Math.ceil(film.source)>=c } "
            ></i>
            <span class="source">{{ (film.source*2).toFixed(1) }}</span>
        </div>
    </div>
    `,
    props:{
        film:{
            type:Object,
            default(){
                return {}
            }
        }
    }
}